Bootstrap: docker
From: ubuntu

%files
	. /planner	

%post
    apt-get update
    apt-get -y install ruby
    ruby -v
    #export RUBY_THREAD_VM_STACK_SIZE=5000000

%runscript
    DOMAINFILE=$1
    PROBLEMFILE=$2
    PLANFILE=$3
    TIME=$4
    MEMORY=$5
    RANDOMSEED=$6
	
	ulimit -s unlimited
    export RUBY_THREAD_VM_STACK_SIZE=$((15 * 1024 * 1024))
    ulimit -a
	echo $RUBY_THREAD_VM_STACK_SIZE
    stdbuf -o0 -e0 ruby --disable=all /planner/Hype.rb $DOMAINFILE $PROBLEMFILE typredicate pullup dejavu run 2>&1 | tee $PLANFILE

%labels
Name        HyperTensioN
Description Hierarchical Task Network planning in Ruby
Authors     Mauricio Cecilio Magnaguagno <mauricio.magnaguagno@acad.pucrs.br> Felipe Meneguzzi <felipe.meneguzzi@pucrs.br> Lavindra de Silva <lavindra.desilva@eng.cam.ac.uk>
SupportsRecursion    yes
SupportsPartialOrder no
